package com.fanghaoran.controller;

import com.fanghaoran.bean.Interaction;
import com.fanghaoran.entity.Sign;
import com.fanghaoran.service.SignService;


/**
 * @Author: win11
 * @Date: 2023/03/23/13:11
 * @Description: 打卡操作的controller层
 */
public class SignController {
    private final SignService signService = new SignService();

    /**
     * 交给service层实现查询打卡信息
     */
    public Interaction selectSignInfo() throws Exception {
        return signService.selectSignInfo();
    }

    /**
     * 交给service层实现更新打卡信息
     */
    public void updateSignInfo(Sign sign) throws Exception {
        signService.updateSignInfo(sign);
    }

    /**
     * 交给service层实现定时更新数据库中是否打卡的flag标志
     */
    public void updateFlag(Sign sign) throws Exception {
        signService.updateFlag(sign);
    }
}
